﻿using ACS.SPiiPlusNET;
using Company.UI.DataClasses;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Company.UI.Models
{
    public class BufferManageControlModel : BindableBase
    {
        private bool _IsConnected = false;
        private double _BuffersCount;

        public BufferState BufferState { get; set; }
        public bool IsConnected
        {
            get { return _IsConnected; }
            set { _IsConnected = value; RaisePropertyChanged(); }
        }
        public double BuffersCount
        {
            get { return _BuffersCount; }
            set { _BuffersCount = value; RaisePropertyChanged(); }
        }
        private int _CurrentBufferId = 0;

        public int CurrentBufferId
        {
            get
            {
                if (_CurrentBufferId < 0)
                {
                    _CurrentBufferId = 0;
                }
                return _CurrentBufferId;
            }
            set { _CurrentBufferId = value; RaisePropertyChanged(); }
        }
        public BufferManageControlModel()
        {
            BufferState = new BufferState();
        }
    }
}
